libubus: process pending messages in data handler if stack depth is 0
authorFelix Fietkau <[email protected]>
Thu, 12 Aug 2021 10:35:19 +0000 (12:35 +0200)
committerPetr Štetiar <[email protected]>
Tue, 15 Feb 2022 17:10:16 +0000 (18:10 +0100)
commitedda23fd018034493168ba67159b20d27570082b
treeab238e829a36e2cd0af13f2930f5687f73aa5d9b
parentc3f3e194870973a888cabc7129f6f8ec0c3cccee
libubus: process pending messages in data handler if stack depth is 0

Process pending messages before attempting to read new ones. After completing
the poll, process any remaining pending messages.

A previous message processing call which issued a request from within
its handler may have left behind more object messages to process.

Signed-off-by: Felix Fietkau <[email protected]>
(cherry picked from commit ef038488edc35f4f671c09276cc3fb4ef706ae34)
libubus-io.c